#include<stdio.h>

typedef int (*doCmd)(char *data, int len);

int insetCmd(int cmd, doCmd handler);
doCmd getCmd(int cmd);